-
Notifications
You must be signed in to change notification settings - Fork 915
[MAINT] Fix github_organization_ruleset and github_repository_ruleset with push target
#2958
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
stevehipwell
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this change likely wants to wait for the SDK upgrade as a lot of this area is modified in future versions.
FYI the error behaviours previously seen should have been mitigated by #2705 so if there is an error the provider should handle it gracefully.
0531db8 to
9dd2965
Compare
1bdfa45 to
efd67ae
Compare
github_organization_ruleset with push targetgithub_organization_ruleset with push target
52d95d4 to
6782aab
Compare
stevehipwell
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would it be possible to either de-scope this PR or open a new PR with the smallest number of changes possible to fix the outstanding bugs?
| }, | ||
| "bypass_actors": { | ||
| Type: schema.TypeList, | ||
| Type: schema.TypeList, // TODO: These are returned from GH API sorted by actor_id, we might want to investigate if we want to include sorting |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should sort the returned values based on the inputs which would stop churn.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That sounds sensible, need to investigate where the best place for the sorting is
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@stevehipwell after some investigation, it seems that schema.TypeSet would be the correct way to implement unsorted. What do you think?
|
@stevehipwell Yes, I agree. I've done that already in this PR: #2976 But I can't switch the base of this PR to point to that :) |
github_organization_ruleset with push targetgithub_organization_ruleset and github_repository_ruleset with push target
1fe74fc to
2a2277a
Compare
stevehipwell
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've added some review comments, mainly about the code structure.
Signed-off-by: Timo Sand <[email protected]>
Signed-off-by: Timo Sand <[email protected]>
Signed-off-by: Timo Sand <[email protected]>
Signed-off-by: Timo Sand <[email protected]>
Signed-off-by: Timo Sand <[email protected]>
Signed-off-by: Timo Sand <[email protected]>
… to org rulesets will never be a thing Signed-off-by: Timo Sand <[email protected]>
Signed-off-by: Timo Sand <[email protected]>
Signed-off-by: Timo Sand <[email protected]>
Signed-off-by: Timo Sand <[email protected]>
Signed-off-by: Timo Sand <[email protected]>
Signed-off-by: Timo Sand <[email protected]>
…esponse Signed-off-by: Timo Sand <[email protected]>
As they differ from `branch` and `tag` rules Signed-off-by: Timo Sand <[email protected]>
Signed-off-by: Timo Sand <[email protected]>
Signed-off-by: Timo Sand <[email protected]>
…ved` repos to be private This allows even EMU users to run these tests Signed-off-by: Timo Sand <[email protected]>
Signed-off-by: Timo Sand <[email protected]>
Signed-off-by: Timo Sand <[email protected]>
…` and `rules` Signed-off-by: Timo Sand <[email protected]>
Signed-off-by: Timo Sand <[email protected]>
Signed-off-by: Timo Sand <[email protected]>
Signed-off-by: Timo Sand <[email protected]>
Signed-off-by: Timo Sand <[email protected]>
…anything Signed-off-by: Timo Sand <[email protected]>
Signed-off-by: Timo Sand <[email protected]>
Signed-off-by: Timo Sand <[email protected]>
Signed-off-by: Timo Sand <[email protected]>
Signed-off-by: Timo Sand <[email protected]>
Signed-off-by: Timo Sand <[email protected]>
Signed-off-by: Timo Sand <[email protected]>
Signed-off-by: Timo Sand <[email protected]>
Signed-off-by: Timo Sand <[email protected]>
…easier debugging Signed-off-by: Timo Sand <[email protected]>
c1019c3 to
d51fea0
Compare
Signed-off-by: Timo Sand <[email protected]>
…thing Signed-off-by: Timo Sand <[email protected]>
Resolves #2929, #2467
Before the change?
ref_namewould cause the provider to Panic asref_nameis a required fieldruleswhich weren't valid forpushrulesetsAfter the change?
pushrulesets to an organizationref_nameshould no longer be needed to be set forpushtargetconditions&targetvalidation logic should ensure correct fields are populatedPull request checklist
Schema migrations have been created if needed (example)Does this introduce a breaking change?
Please see our docs on breaking changes to help!